home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 3898 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  1.7 KB

  1. Path: nntp-xfer-2.csn.net!yuma!steffend
  2. From: steffend@lamar.colostate.edu (Dave Steffen)
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: randon number generator
  5. Date: 26 Jan 1996 17:07:16 GMT
  6. Organization: Colorado State University, Fort Collins, CO  80523
  7. Message-ID: <4eb1o4$3hfo@yuma.ACNS.ColoState.EDU>
  8. References: <4e6qt1$adb@ns.campus.mci.net> <DLr1H5.In8@rose.com>
  9. NNTP-Posting-Host: glitch.physics.colostate.edu
  10. X-Newsreader: TIN [version 1.2 PL2]
  11.  
  12. A White (awhite@user.rose.com) wrote:
  13. > In article <4e6qt1$adb@ns.campus.mci.net>,
  14. > jack wilson <wilsojt@occ-uky.campus.mci.net> wrote:
  15. > >Hello all....I need a random number generator ...if anyone should have 
  16. > >C or C++ source for this I would appreciate it. Please e-mail me at 
  17. > >wilsojt@occ-uky.campus.mci.net   Thanks in advance Jack
  18.  
  19. > Why not include stdlib and use rand() and srand(<int>)
  20.  
  21.     Because those functions are not always very good random number
  22. generators, i.e. the sequences of numbers they generate may have
  23. correlations. According to "Numerical Recipies in C" (2nd Ed),
  24. 'system-supplied' generators have a dismal track record. There's
  25. another post in this thread that mentions several good sources, I'd go
  26. there to get my code.
  27.  
  28.                                  /\
  29.                                  \/
  30.  
  31. Dave Steffen                      No, his mind is not for rent
  32. Dept. of Physics                  To any God or Government
  33. Colorado State University         Always hopeful, yet discontent
  34. steffend@lamar.colostate edu      He knows changes aren't permanent-
  35.                       But change is...
  36. "Speak softly...                    
  37. ... and carry a black belt!"              -Neal Peart / RUSH
  38. -----------------------------------------------------------------------
  39.